package de.hpi.generator.model;

import de.hpi.generator.config.ColumnModel;

public class IntegerColumn extends Column {



	public IntegerColumn(ColumnModel aColumnModel, Table aOwner) throws Exception {
		super(aColumnModel, aOwner);
	}
	
	public String getColumnName() {
		return "Integer";
	}
	
	public String convertToStringWithFestLength(int aValue) throws Exception{
		String result = "";
		if (aValue<0){
			result+="-";
			aValue = -aValue;
		}
		for (int i = 0; i < super.aCellSize  ; i++) {
			int aModuloValue = aValue%10;
			result+=String.valueOf(aModuloValue);
			aValue = aValue/10;
		}
		return result;
	}
        
        public String convertToString(int aValue){
            return String.valueOf(aValue);
        }
        


}
